//用户模块

//.当前，..上级
import axios from '../utils/request';

//Role查询
export const getRoleList=q=>{
    return axios({
        url:'/api/Role/RoleLimitsShow',
        method:'get',
        params:q,
    })
}
//Role删除
export const DelRoleList=Id=>{
    return axios({
        url:'/api/Role/RoleDeleteId',
        method:'get',
        params:Id,
    })
}
//Role添加
export const AddRole=a=>{
    return axios({
        url:'/api/Role/RoleAdd',
        method:'post',
        data:a 
    })
}
//Role修改
export const UptRole=a=>{
    return axios({
        url:'/api/Role/RoleUptdate',
        method:'post',
        data:a 
    })
}
//User登录
export const loginUser=d=>{
    return axios({
        //接口地址
        url:'api/User/Login',
        method:'post',
        data:d //body请求传参
    })
}
//User查询
export const getUserList=q=>{
    return axios({
        url:'/api/User/UserRoleShow',
        method:'get',
        params:q,
    })
}
//User修改
export const UptUser=a=>{
    return axios({
        url:'/api/User/UserUptdate',
        method:'post',
        data:a 
    })
}
//User删除
export const DelUserList=Id=>{
    return axios({
        url:'/api/User/UserDeleteId',
        method:'get',
        params:Id,
    })
}
//User添加
export const AddUser=a=>{
    return axios({
        url:'/api/User/UserAdd',
        method:'post',
        data:a 
    })
}